<template>
  <h1>父组件</h1>
  <LifeCycleSonView />
  <img :src="imgSrc" alt="">
</template>
<script setup lang="ts">
import LifeCycleSonView from '../vue/LifeCycleSonView.vue'
import { onBeforeMount, onMounted, onBeforeUnmount, onUnmounted } from 'vue'
import imgSrc from '@/img/父子组件生命周期.png'
onBeforeMount(() => {
  console.log('父组件onBeforeMount')
})
onMounted(() => {
  console.log('父组件onMounted')
})
onBeforeUnmount(() => {
  console.log('父组件onBeforeUnmount')
})
onUnmounted(() => {
  console.log('父组件onUnmounted')
})
</script>
